Likewise, if the queue is empty, the reader thread would wait on the_rcond variable, and a writer thread sends a broadcast to all threads waiting on_rcond after inserting data into the queue. 同样,如果队列是空的,读线程等待rcond变量,写线程在把数据插入队列中之后向所有线程发送广播消息。
The experiment results show that PBQS selects the broadcast content dynamically, which based on the current user query queue state. 实验结果表明:PBQS策略能根据用户请求队列状态动态选择数据,响应率高,选择开销少;